#include "dev_e53_smoke.h"
#include "main.h"


#if defined (E53_SF1)
#define MQ2_Sensor_Pin GPIO_PIN_2
#define MQ2_Sensor_GPIO_Port GPIOC
extern ADC_HandleTypeDef hadc1;
#endif

void smoke_dev_init(void)
{
		#if defined (E53_SF1)
		
		#endif
}


uint16_t get_smoke_dev_value(void)
{
		#if defined (E53_SF1)
    HAL_ADC_Start(&hadc1);
    HAL_ADC_PollForConversion(&hadc1, 50);	
    return HAL_ADC_GetValue(&hadc1);
		#endif
	
		#if ! defined (E53_SF1)
		return 0 ;
		#endif
}

e53_smoke_dev smoke_dev =
{
    .e53_smoke_init				=	smoke_dev_init,
    .e53_get_smoke_value	=	get_smoke_dev_value,
};

